﻿
using Microsoft.AspNetCore.Mvc;

namespace GCC.APIContainer.Auth.Results
{
    /// <summary>
    /// 异常返回
    /// </summary>
    public class ForbidResult : IActionResult
    {
        /// <summary>
        /// 响应
        /// </summary>
        /// <param name="context"></param>
        /// <returns></returns>
        public Task ExecuteResultAsync(ActionContext context) => Task.Run(() =>
        {
            context.HttpContext.Response.StatusCode = 401;
        });
    }
}
